class UserConstants {
    static PASSWORD_NOT_MATCH = '密码长度要求5-20的任意字符'
    static USERNAME_NOT_MATCH = '账号长度要求2-20的任意字符'
    static NICKNAME_NOT_MATCH = '昵称长度要求2-20的任意字符'
    static PHONE_NOT_MATCH = '电话格式不合法'
    static EMAIL_NOT_MATCH = '邮箱格式不合法'
    static USERNAME_MIN_LENGTH = 2
    static USERNAME_MAX_LENGTH = 20
    static PASSWORD_MIN_LENGTH = 5
    static PASSWORD_MAX_LENGTH = 20
    static MOBILE_PHONE_NUMBER_PATTERN = /^0{0,1}(13[0-9]|15[0-9]|14[0-9]|18[0-9])[0-9]{8}$/

    static EMAIL_PATTERN = /[\w!#$%&'*+/=?^_`{|}~-]+(?:\.[\w!#$%&'*+/=?^_`{|}~-]+)*@(?:[\w](?:[\w-]*[\w])?\.)+[\w](?:[\w-]*[\w])?/
}

class CategoryConstants {

    static CATEGORY_NAME_MIN_LEN = 1
    static CATEGORY_NAME_MAX_LEN = 5

    static CATEGORY_NAME_NOT_MATCH = '分类名长度要求1-5位的任意字符'

}


class GoodsConstants {

    static GOODS_NAME_MIN_LEN = 1
    static GOODS_NAME_MAX_LEN = 30

    static GOODS_NAME_NOT_MATCH = '产品名长度要求1-30位的任意字符'

}


const statusOptions = [
    {
        value: "0",
        label: "正常",
    },
    {
        value: "1",
        label: "停用",
    },
]

export { UserConstants, CategoryConstants, GoodsConstants, statusOptions }